package com.alks.entity.data.entity.dispatch;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.annotation.JsonIgnore;
import org.apache.commons.lang3.time.DateUtils;
import org.springframework.format.annotation.DateTimeFormat;

import javax.validation.constraints.NotEmpty;
import java.io.Serializable;
import java.text.ParseException;
import java.util.*;

public class OemLotHead implements Serializable {
    private String companyId;
    private @NotEmpty(
            message = "编号不能为空"
    ) String uuid;
    private String brand;
    private String vendorNo;
    private String vendorAbbr;
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date customOrderDate;
    private String customOrderTime;
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date predicProdDate;
    private String predicProdTime;
    private String season;
    private String orderType;
    private String factoryContractNo;
    private String customPiNo;
    private String lotNo;
    private String factoryLotNo;
    private String styleNo;
    private String styleColor;
    private int orderQty;
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date deliveryDate;
    private String deliveryTime;
    private boolean cutSample;

    public String getCutSampleS() {
        return cutSampleS;
    }

    public void setCutSampleS(String cutSampleS) {
        this.cutSampleS = this.cfsSample ? "是" : "否";
    }

    public String getAntenatalSampleS() {
        return antenatalSampleS;
    }

    public void setAntenatalSampleS(String antenatalSampleS) {
        this.antenatalSampleS = this.antenatalSample ? "是" : "否";
    }

    public String getTryOnSampleS() {
        return tryOnSampleS;
    }

    public void setTryOnSampleS(String tryOnSampleS) {
        this.tryOnSampleS = this.tryOnSample ? "是" : "否";
    }

    public String getTestSampleS() {
        return testSampleS;
    }

    public void setTestSampleS(String testSampleS) {
        this.testSampleS = this.testSample ? "是" : "否";
    }

    public String getCfsSampleS() {
        return cfsSampleS;
    }

    public void setCfsSampleS(String cfsSampleS) {
        this.cfsSampleS = this.cfsSample ? "是" : "否";
    }

    public String getRawMaterialS() {
        return rawMaterialS;
    }

    public void setRawMaterialS(String rawMaterialS) {
        this.rawMaterialS = this.rawMaterial ? "是" : "否";
    }

    public String getShoeLaceS() {
        return shoeLaceS;
    }

    public void setShoeLaceS(String shoeLaceS) {
        this.shoeLaceS = this.shoelace ? "是" : "否";
    }

    public String getCompleteName() {
        return completeName;
    }

    public void setCompleteName(String completeName) {
        this.completeName = this.complete ? "是" : "否";
    }

    private String cutSampleS;
    private boolean antenatalSample;
    private String antenatalSampleS;
    private boolean tryOnSample;
    private String tryOnSampleS;
    private boolean testSample;
    private String testSampleS;
    private boolean cfsSample;
    private String cfsSampleS;
    private boolean rawMaterial;

    private String rawMaterialS;
    private boolean shoelace;
    private String shoeLaceS;
    private int cutQty;
    private int craftQty;
    private int matchQty;
    private int stitchQty;
    private int outSoleQty;
    private int insoleQty;
    private int finishQty;
    private String remark;
    private Integer createUserId;
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date createDate;
    private String createTime;
    private String createUserName;
    private boolean complete;

    private String completeName;
    private String custStyle;
    private String soleVendor;
    private String lastMold;
    private String cutTool;
    private String solePart;
    private Map<String, Object> params;
    private List<UserOemRelation> oemList;
    @JsonIgnore
    private String customOrderDateStr;
    @JsonIgnore
    private String predicProdDateStr;
    @JsonIgnore
    private String deliveryDateStr;
    @JsonIgnore
    private byte[] colorPhoto;
    private Double custPrice;
    private String custCur;
    private Double factoryPrice;
    private String factoryCur;
    private String isCfm;
    private int outQty;
    private String styleName;
    private String custName;
    private String exportCfm;
    private Long userId;
    private Double payAmt;
    private Calendar calendar = new GregorianCalendar(1900, 0, -1);
    private String colorCode;

    private Integer pageNum;

    private Integer pageSize;

    public Integer getPageNum() {
        return pageNum;
    }

    public void setPageNum(Integer pageNum) {
        this.pageNum = pageNum;
    }

    public Integer getPageSize() {
        return pageSize;
    }

    public void setPageSize(Integer pageSize) {
        this.pageSize = pageSize;
    }

    private static final long serialVersionUID = 1L;

    public OemLotHead() {
    }

    public Long getUserId() {
        return this.userId;
    }

    public void setUserId(Long userId) {
        this.userId = userId;
    }

    public String getColorCode() {
        return this.colorCode;
    }

    public void setColorCode(String colorCode) {
        this.colorCode = colorCode;
    }

    public String getExportCfm() {
        return this.exportCfm;
    }

    public void setExportCfm(String exportCfm) {
        this.exportCfm = exportCfm;
    }

    public Double getPayAmt() {
        return this.payAmt;
    }

    public void setPayAmt(Double payAmt) {
        this.payAmt = payAmt;
    }

    public String getStyleName() {
        return this.styleName;
    }

    public void setStyleName(String styleName) {
        this.styleName = styleName;
    }

    public String getCustName() {
        return this.custName;
    }

    public void setCustName(String custName) {
        this.custName = custName;
    }

    public int getOutQty() {
        return this.outQty;
    }

    public void setOutQty(int outQty) {
        this.outQty = outQty;
    }

    public String getIsCfm() {
        return this.isCfm;
    }

    public void setIsCfm(String isCfm) {
        this.isCfm = isCfm;
    }

    public Double getCustPrice() {
        return this.custPrice;
    }

    public void setCustPrice(Double custPrice) {
        this.custPrice = custPrice;
    }

    public String getCustCur() {
        return this.custCur;
    }

    public void setCustCur(String custCur) {
        this.custCur = custCur;
    }

    public Double getFactoryPrice() {
        return this.factoryPrice;
    }

    public void setFactoryPrice(Double factoryPrice) {
        this.factoryPrice = factoryPrice;
    }

    public String getFactoryCur() {
        return this.factoryCur;
    }

    public void setFactoryCur(String factoryCur) {
        this.factoryCur = factoryCur;
    }

    public String getUuid() {
        return this.uuid;
    }

    public void setUuid(String uuid) {
        this.uuid = uuid == null ? null : uuid.trim();
    }

    public String getVendorNo() {
        return this.vendorNo;
    }

    public void setVendorNo(String vendorNo) {
        this.vendorNo = vendorNo == null ? null : vendorNo.trim();
    }

    public String getVendorAbbr() {
        return this.vendorAbbr;
    }

    public void setVendorAbbr(String vendorAbbr) {
        this.vendorAbbr = vendorAbbr == null ? null : vendorAbbr.trim();
    }

    public Date getCustomOrderDate() {
        return this.customOrderDate;
    }

    public void setCustomOrderDate(Date customOrderDate) {
        this.customOrderDate = customOrderDate;
    }

    public Date getPredicProdDate() {
        return this.predicProdDate;
    }

    public void setPredicProdDate(Date predicProdDate) {
        this.predicProdDate = predicProdDate;
    }

    public String getSeason() {
        return this.season;
    }

    public void setSeason(String season) {
        this.season = season == null ? null : season.trim();
    }

    public String getOrderType() {
        return this.orderType;
    }

    public void setOrderType(String orderType) {
        this.orderType = orderType == null ? null : orderType.trim();
    }

    public String getFactoryContractNo() {
        return this.factoryContractNo;
    }

    public void setFactoryContractNo(String factoryContractNo) {
        this.factoryContractNo = factoryContractNo == null ? null : factoryContractNo.trim();
    }

    public String getCustomPiNo() {
        return this.customPiNo;
    }

    public void setCustomPiNo(String customPiNo) {
        this.customPiNo = customPiNo == null ? null : customPiNo.trim();
    }

    public String getLotNo() {
        return this.lotNo;
    }

    public void setLotNo(String lotNo) {
        this.lotNo = lotNo == null ? null : lotNo.trim();
    }

    public String getFactoryLotNo() {
        return this.factoryLotNo;
    }

    public void setFactoryLotNo(String factoryLotNo) {
        this.factoryLotNo = factoryLotNo == null ? null : factoryLotNo.trim();
    }

    public String getStyleNo() {
        return this.styleNo;
    }

    public void setStyleNo(String styleNo) {
        this.styleNo = styleNo == null ? null : styleNo.trim();
    }

    public String getStyleColor() {
        return this.styleColor;
    }

    public void setStyleColor(String styleColor) {
        this.styleColor = styleColor == null ? null : styleColor.trim();
    }

    public Date getDeliveryDate() {
        return this.deliveryDate;
    }

    public void setDeliveryDate(Date deliveryDate) {
        this.deliveryDate = deliveryDate;
    }

    public int getOrderQty() {
        return this.orderQty;
    }

    public void setOrderQty(int orderQty) {
        this.orderQty = orderQty;
    }

    public boolean isCutSample() {
        return this.cutSample;
    }

    public void setCutSample(boolean cutSample) {
        this.cutSample = cutSample;
    }

    public boolean isAntenatalSample() {
        return this.antenatalSample;
    }

    public void setAntenatalSample(boolean antenatalSample) {
        this.antenatalSample = antenatalSample;
    }

    public boolean isTryOnSample() {
        return this.tryOnSample;
    }

    public void setTryOnSample(boolean tryOnSample) {
        this.tryOnSample = tryOnSample;
    }

    public boolean isTestSample() {
        return this.testSample;
    }

    public void setTestSample(boolean testSample) {
        this.testSample = testSample;
    }

    public boolean isCfsSample() {
        return this.cfsSample;
    }

    public void setCfsSample(boolean cfsSample) {
        this.cfsSample = cfsSample;
    }

    public boolean isRawMaterial() {
        return this.rawMaterial;
    }

    public void setRawMaterial(boolean rawMaterial) {
        this.rawMaterial = rawMaterial;
    }

    public boolean isShoelace() {
        return this.shoelace;
    }

    public void setShoelace(boolean shoelace) {
        this.shoelace = shoelace;
    }

    public int getCutQty() {
        return this.cutQty;
    }

    public void setCutQty(int cutQty) {
        this.cutQty = cutQty;
    }

    public int getCraftQty() {
        return this.craftQty;
    }

    public void setCraftQty(int craftQty) {
        this.craftQty = craftQty;
    }

    public int getMatchQty() {
        return this.matchQty;
    }

    public void setMatchQty(int matchQty) {
        this.matchQty = matchQty;
    }

    public int getStitchQty() {
        return this.stitchQty;
    }

    public void setStitchQty(int stitchQty) {
        this.stitchQty = stitchQty;
    }

    public int getOutSoleQty() {
        return this.outSoleQty;
    }

    public void setOutSoleQty(int outSoleQty) {
        this.outSoleQty = outSoleQty;
    }

    public int getInsoleQty() {
        return this.insoleQty;
    }

    public void setInsoleQty(int insoleQty) {
        this.insoleQty = insoleQty;
    }

    public int getFinishQty() {
        return this.finishQty;
    }

    public void setFinishQty(int finishQty) {
        this.finishQty = finishQty;
    }

    public String getRemark() {
        return this.remark;
    }

    public void setRemark(String remark) {
        this.remark = remark == null ? null : remark.trim();
    }

    public Integer getCreateUserId() {
        return this.createUserId;
    }

    public void setCreateUserId(Integer createUserId) {
        this.createUserId = createUserId;
    }

    public Date getCreateDate() {
        return this.createDate;
    }

    public void setCreateDate(Date createDate) {
        this.createDate = createDate;
    }

    public String getCreateUserName() {
        return this.createUserName;
    }

    public void setCreateUserName(String createUserName) {
        this.createUserName = createUserName;
    }

    public Map<String, Object> getParams() {
        return this.params;
    }

    public void setParams(Map<String, Object> params) {
        this.params = params;
    }

    public String getCompanyId() {
        return this.companyId;
    }

    public void setCompanyId(String companyId) {
        this.companyId = companyId;
    }

    public void setCustomOrderDateStr(String customOrderDateStr) throws ParseException {
        this.customOrderDateStr = customOrderDateStr;

        try {
            int intDay = Integer.parseInt(customOrderDateStr);
            this.customOrderDate = DateUtils.addDays(this.calendar.getTime(), intDay);
        } catch (Exception var3) {
            this.customOrderDate = DateUtils.parseDate(customOrderDateStr);
        }

    }

    public void setPredicProdDateStr(String predicProdDateStr) throws ParseException {
        this.predicProdDateStr = predicProdDateStr;

        try {
            int intDay = Integer.parseInt(predicProdDateStr);
            this.predicProdDate = DateUtils.addDays(this.calendar.getTime(), intDay);
        } catch (Exception var3) {
            this.predicProdDate = DateUtils.parseDate(predicProdDateStr);
        }

    }

    public void setDeliveryDateStr(String deliveryDateStr) throws ParseException {
        this.deliveryDateStr = deliveryDateStr;

        try {
            int intDay = Integer.parseInt(deliveryDateStr);
            this.deliveryDate = DateUtils.addDays(this.calendar.getTime(), intDay);
        } catch (Exception var3) {
            this.deliveryDate = DateUtils.parseDate(deliveryDateStr);
        }

    }

    public String getBrand() {
        return this.brand;
    }

    public void setBrand(String brand) {
        this.brand = brand;
    }

    public List<UserOemRelation> getOemList() {
        return this.oemList;
    }

    public void setOemList(List<UserOemRelation> oemList) {
        this.oemList = oemList;
    }

    public boolean isComplete() {
        return this.complete;
    }

    public void setComplete(boolean complete) {
        this.complete = complete;
    }

    public byte[] getColorPhoto() {
        return this.colorPhoto;
    }

    public void setColorPhoto(byte[] colorPhoto) {
        this.colorPhoto = colorPhoto;
    }

    public String getCustStyle() {
        return this.custStyle;
    }

    public void setCustStyle(String custStyle) {
        this.custStyle = custStyle;
    }

    public String getSoleVendor() {
        return this.soleVendor;
    }

    public void setSoleVendor(String soleVendor) {
        this.soleVendor = soleVendor;
    }

    public String getLastMold() {
        return this.lastMold;
    }

    public void setLastMold(String lastMold) {
        this.lastMold = lastMold;
    }

    public String getCutTool() {
        return this.cutTool;
    }

    public void setCutTool(String cutTool) {
        this.cutTool = cutTool;
    }

    public String getSolePart() {
        return this.solePart;
    }

    public void setSolePart(String solePart) {
        this.solePart = solePart;
    }

    public String toString() {
        return "OemLotHead [uuid=" + this.uuid + ", vendorNo=" + this.vendorNo + ", vendorAbbr=" + this.vendorAbbr + ", customOrderDate=" + this.customOrderDate + ", predicProdDate=" + this.predicProdDate + ", season=" + this.season + ", orderType=" + this.orderType + ", factoryContractNo=" + this.factoryContractNo + ", customPiNo=" + this.customPiNo + ", lotNo=" + this.lotNo + ", factoryLotNo=" + this.factoryLotNo + ", styleNo=" + this.styleNo + ", styleColor=" + this.styleColor + ", orderQty=" + this.orderQty + ", deliveryDate=" + this.deliveryDate + ", cutSample=" + this.cutSample + ", antenatalSample=" + this.antenatalSample + ", tryOnSample=" + this.tryOnSample + ", testSample=" + this.testSample + ", cfsSample=" + this.cfsSample + ", rawMaterial=" + this.rawMaterial + ", shoelace=" + this.shoelace + ", cutQty=" + this.cutQty + ", craftQty=" + this.craftQty + ", matchQty=" + this.matchQty + ", stitchQty=" + this.stitchQty + ", outSoleQty=" + this.outSoleQty + ", insoleQty=" + this.insoleQty + ", finishQty=" + this.finishQty + ", remark=" + this.remark + ", createUserId=" + this.createUserId + ", createDate=" + this.createDate + ", createUserName=" + this.createUserName + "]";
    }

    public String getCustomOrderTime() {
        return customOrderTime;
    }

    public void setCustomOrderTime(String customOrderTime) {
        this.customOrderTime = customOrderTime;
    }

    public String getPredicProdTime() {
        return predicProdTime;
    }

    public void setPredicProdTime(String predicProdTime) {
        this.predicProdTime = predicProdTime;
    }

    public String getDeliveryTime() {
        return deliveryTime;
    }

    public void setDeliveryTime(String deliveryTime) {
        this.deliveryTime = deliveryTime;
    }

    public String getCreateTime() {
        return createTime;
    }

    public void setCreateTime(String createTime) {
        this.createTime = createTime;
    }
}
